<script setup lang="ts">
const props = defineProps({
  title: {
    type: String,
    default: '',
  },
  desc: {
    type: String,
    default: '',
  },
  bold: {
    type: String,
    default: '',
  },
  tips: {
    type: String,
    default: '',
  },
  src: {
    type: null,
    default: '',
  },
  text: {
    type: String,
    default: '一键创建',
  },
})

function handleClick() {
  uni.navigateTo({
    url: props.src,
  })
}
</script>

<template>
  <div class="gradient" mt-30rpx round>
    <div text-34rpx>
      {{ props.title }}
    </div>
    <div text-28rpx mt-30rpx color="#999999">
      {{ props.desc }}
    </div>
    <div mt-30rpx mb-50rpx font-500 class="main-color">
      <span text-32rpx font-600>
        {{ props.bold }}
      </span><span text-28rpx>{{ props.tips }}</span>
    </div>
    <nut-button block round shape="square" type="primary" @click="handleClick">
      {{ props.text }}
    </nut-button>
  </div>
</template>

<style scoped lang="scss">
.gradient {
  background: #fff;
  padding: 32rpx;
}

.nut-button--square {
  border-radius: 10rpx;
}
</style>
